const files = require.context(".", true, /\.vue$/);
export default {
  install: (Vue) => {
    files.keys().forEach((ele) => {
      const ctrl = files(ele).default || files(ele);
      let name = ctrl.name || ele.split("/")[ele.split("/").length-2];
      Vue.component(name, ctrl);
    })
  }
};
